//
//  SelectCarViewModel.m
//  Park
//
//  Created by 123456 on 2017/11/4.
//  Copyright © 2017年 YTYangK. All rights reserved.
//

#import "SelectCarViewModel.h"
#import "SelectCarModel.h"
@implementation SelectCarViewModel




+(void)requestWithUrlForSelectCar:(id)obj andParam:(NSDictionary *)param success:(void (^)(NSMutableArray *))success failure:(void (^)(NSString *))failure{
    
    
    [NetRequestClss requestWithUrl:@"app/CarList.do" requestWithParameters:param method:NetMethodGET returnSuccess:^(id objs, int status, NSString *mag) {
        
        NSLog(@"请求返回 ===== %@",objs);
      
        if ([objs[@"result"] isEqualToString:@"success"]) {
            
            success(objs[@"body"][@"carDPs"]);
            
        }else{
            failure(objs[@"msg"]);

        }
        
        
    } returnError:^(NSString *err) {
        failure(err);

    }];
    
    
}



@end
